import component.TeacherComponent;
import controller.TestController;
import controller.UserController;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class App {
    public static void main(String[] args) {
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("spring-config.xml");
/*        UserController userController = context.getBean(UserController.class);
        TestController testController = context.getBean(TestController.class);
        userController.setUser();
        testController.setUser();*/
        TeacherComponent teacherComponent = context.getBean(TeacherComponent.class);
        teacherComponent.sayhi();
        context.destroy();
    }
}
